Incremental Generation of LR Parsers
نویسنده
چکیده
Implementation of a new compiler usually requires making frequent adjustments to grammar de nitions. An incremental technique for updating the parser tables after a minor change to the grammar could potentially save much computational e ort. More importantly, debugging a grammar is made easier if the grammar is re-checked for correctness after each small change to the grammar. The basic design philosophy of an incremental parser generator, and incremental algorithms for LR(0), SLR(1) and LALR(1) parser generation are discussed in this paper. Some of these algorithms have been incorporated into an implementation of an incremental LALR(1) parser generator. Index Terms { Compilers, Compiler Tools, Program Development Environments, LR Parsing, LALR(1), SLR(1), Incremental Algorithms, Grammar Debugging.
منابع مشابه
Comparison of Syntactic Error Handling in LR Parsers
Error recovery techniques for LR parsers presented in the literature are described and classified. The techniques considered range from the non-correcting ones to interactive and incremental ones. Also, some of the techniques presented are compared and evaluated. An example showing the advantages and the disadvantages of each class of strategies is given and is used as a guideline for classifyi...
متن کاملVisual Language Editors Based on Lr Parsing Techniques
Visual language editors should provide a user-friendly environment where users are supported in an effective way in the construction of visual sentences. In this paper, we propose an approach for the construction of syntax-directed visual language editors by integrating incremental parsers into freehand editors. The approach combines the LR-based techniques for parsing visual languages with the...
متن کاملAn Incremental LR Parse Strategy for Language - Based EditorsPhil
We present an incremental parser for a modeless syntax recognising language-based editor. The strategy we describe has been implemented as part of the UQ? generic language-based environment. Incremental parsing in the UQ? editor has previously been based on LL techniques. The incremen-tal LR parser described in this report has been developed to allow manipulation of a larger class of languages ...
متن کاملIncremental Parser Generation for Tree Adjoining Grammars
This paper describes the incremental generation of parse tables for the LRtype parsing of Tree Adjoining Languages (TALs). The algorithm presented handles modi cations to the input grammar by updating the parser generated so far. In this paper, a lazy generation of LR-type parsers for TALs is de ned in which parse tables are created by need while parsing. We then describe an incremental parser ...
متن کاملA Bounded Graph-Connect Construction for LR-regular Parsers
Parser generation tools currently used for computer language analysis rely on user wisdom in order to resolve grammar conflicts. Here practical LR(0)-based parser generation is introduced, with automatic conflict resolution by potentially-unbounded lookahead exploration. The underlying LR(0)-automaton item dependence graph is used for lookahead DFA construction. A bounded graph-connect techniqu...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
- Comput. Lang.
دوره 15 شماره
صفحات -
تاریخ انتشار 1990